package cn.edu.nwafu.core.pojo.entity;

import cn.edu.nwafu.core.config.LocalDateTimeConverter;
import com.alibaba.excel.annotation.ExcelProperty;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.Date;

/**
 * <p>
 *
 * </p>
 *
 * @author zhanghao
 * @since 2021-10-30
 */
@Data
@EqualsAndHashCode(callSuper = false)
@ApiModel(value = "AircraftInfo对象", description = "")
public class AircraftInfo implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "编号")
    @TableId(value = "id", type = IdType.AUTO)
    @ExcelProperty(value = "编号",index = 0)
    private Long id;

    @ApiModelProperty(value = "飞机序列号")
    @ExcelProperty(value = "飞机序列号",index = 1)
    private String aircraftSequence;

    @ApiModelProperty(value = "出发城市")
    @ExcelProperty(value = "出发城市",index = 2)
    private String startCity;

    @ApiModelProperty(value = "出发机场")
    @ExcelProperty(value = "出发机场",index = 3)
    private String startAirport;

    @ApiModelProperty(value = "到达城市")
    @ExcelProperty(value = "到达城市",index = 4)
    private String reachCity;

    @ApiModelProperty(value = "到达机场")
    @ExcelProperty(value = "到达机场",index = 5)
    private String reachAirport;

    @ApiModelProperty(value = "出发时间")
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd")
//    @ExcelProperty(value = "出发时间",index = 6,converter = LocalDateTimeConverter.class)
    private Date startTime;

    @ApiModelProperty(value = "到达时间")
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd")
//    @ExcelProperty(value = "到达时间",index = 7,converter = LocalDateTimeConverter.class)
    private Date reachTime;

    @ApiModelProperty(value = "经济舱价格")
    @ExcelProperty(value = "经济舱价格",index = 8)
    private BigDecimal economyClassPrice;

    @ApiModelProperty(value = "商务舱/头等舱价格")
    @ExcelProperty(value = "商务舱/头等舱价格",index = 9)
    private BigDecimal businessClassPrice;

    @ApiModelProperty(value = "此航班数量")
    @ExcelProperty(value = "此航班数量",index = 10)
    private Integer ticketsNum;


}
